package com.quanyan.runningriding.entity.db;

import com.quanyan.common.Plugin.Page;
import java.util.ArrayList;
import java.util.List;

public class TbRunLevelExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    protected Page page;

    public TbRunLevelExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    public void setPage(Page page) {
        this.page=page;
    }

    public Page getPage() {
        return page;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andLevelIdIsNull() {
            addCriterion("level_id is null");
            return (Criteria) this;
        }

        public Criteria andLevelIdIsNotNull() {
            addCriterion("level_id is not null");
            return (Criteria) this;
        }

        public Criteria andLevelIdEqualTo(Integer value) {
            addCriterion("level_id =", value, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelIdNotEqualTo(Integer value) {
            addCriterion("level_id <>", value, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelIdGreaterThan(Integer value) {
            addCriterion("level_id >", value, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("level_id >=", value, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelIdLessThan(Integer value) {
            addCriterion("level_id <", value, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelIdLessThanOrEqualTo(Integer value) {
            addCriterion("level_id <=", value, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelIdIn(List<Integer> values) {
            addCriterion("level_id in", values, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelIdNotIn(List<Integer> values) {
            addCriterion("level_id not in", values, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelIdBetween(Integer value1, Integer value2) {
            addCriterion("level_id between", value1, value2, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelIdNotBetween(Integer value1, Integer value2) {
            addCriterion("level_id not between", value1, value2, "levelId");
            return (Criteria) this;
        }

        public Criteria andLevelNameIsNull() {
            addCriterion("level_name is null");
            return (Criteria) this;
        }

        public Criteria andLevelNameIsNotNull() {
            addCriterion("level_name is not null");
            return (Criteria) this;
        }

        public Criteria andLevelNameEqualTo(String value) {
            addCriterion("level_name =", value, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameNotEqualTo(String value) {
            addCriterion("level_name <>", value, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameGreaterThan(String value) {
            addCriterion("level_name >", value, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameGreaterThanOrEqualTo(String value) {
            addCriterion("level_name >=", value, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameLessThan(String value) {
            addCriterion("level_name <", value, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameLessThanOrEqualTo(String value) {
            addCriterion("level_name <=", value, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameLike(String value) {
            addCriterion("level_name like", value, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameNotLike(String value) {
            addCriterion("level_name not like", value, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameIn(List<String> values) {
            addCriterion("level_name in", values, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameNotIn(List<String> values) {
            addCriterion("level_name not in", values, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameBetween(String value1, String value2) {
            addCriterion("level_name between", value1, value2, "levelName");
            return (Criteria) this;
        }

        public Criteria andLevelNameNotBetween(String value1, String value2) {
            addCriterion("level_name not between", value1, value2, "levelName");
            return (Criteria) this;
        }

        public Criteria andTotalMileageIsNull() {
            addCriterion("total_mileage is null");
            return (Criteria) this;
        }

        public Criteria andTotalMileageIsNotNull() {
            addCriterion("total_mileage is not null");
            return (Criteria) this;
        }

        public Criteria andTotalMileageEqualTo(Double value) {
            addCriterion("total_mileage =", value, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andTotalMileageNotEqualTo(Double value) {
            addCriterion("total_mileage <>", value, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andTotalMileageGreaterThan(Double value) {
            addCriterion("total_mileage >", value, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andTotalMileageGreaterThanOrEqualTo(Double value) {
            addCriterion("total_mileage >=", value, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andTotalMileageLessThan(Double value) {
            addCriterion("total_mileage <", value, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andTotalMileageLessThanOrEqualTo(Double value) {
            addCriterion("total_mileage <=", value, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andTotalMileageIn(List<Double> values) {
            addCriterion("total_mileage in", values, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andTotalMileageNotIn(List<Double> values) {
            addCriterion("total_mileage not in", values, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andTotalMileageBetween(Double value1, Double value2) {
            addCriterion("total_mileage between", value1, value2, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andTotalMileageNotBetween(Double value1, Double value2) {
            addCriterion("total_mileage not between", value1, value2, "totalMileage");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesIsNull() {
            addCriterion("kilo42_times is null");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesIsNotNull() {
            addCriterion("kilo42_times is not null");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesEqualTo(Integer value) {
            addCriterion("kilo42_times =", value, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesNotEqualTo(Integer value) {
            addCriterion("kilo42_times <>", value, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesGreaterThan(Integer value) {
            addCriterion("kilo42_times >", value, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesGreaterThanOrEqualTo(Integer value) {
            addCriterion("kilo42_times >=", value, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesLessThan(Integer value) {
            addCriterion("kilo42_times <", value, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesLessThanOrEqualTo(Integer value) {
            addCriterion("kilo42_times <=", value, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesIn(List<Integer> values) {
            addCriterion("kilo42_times in", values, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesNotIn(List<Integer> values) {
            addCriterion("kilo42_times not in", values, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesBetween(Integer value1, Integer value2) {
            addCriterion("kilo42_times between", value1, value2, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimesNotBetween(Integer value1, Integer value2) {
            addCriterion("kilo42_times not between", value1, value2, "kilo42Times");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeIsNull() {
            addCriterion("kilo42_time is null");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeIsNotNull() {
            addCriterion("kilo42_time is not null");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeEqualTo(Long value) {
            addCriterion("kilo42_time =", value, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeNotEqualTo(Long value) {
            addCriterion("kilo42_time <>", value, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeGreaterThan(Long value) {
            addCriterion("kilo42_time >", value, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeGreaterThanOrEqualTo(Long value) {
            addCriterion("kilo42_time >=", value, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeLessThan(Long value) {
            addCriterion("kilo42_time <", value, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeLessThanOrEqualTo(Long value) {
            addCriterion("kilo42_time <=", value, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeIn(List<Long> values) {
            addCriterion("kilo42_time in", values, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeNotIn(List<Long> values) {
            addCriterion("kilo42_time not in", values, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeBetween(Long value1, Long value2) {
            addCriterion("kilo42_time between", value1, value2, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42TimeNotBetween(Long value1, Long value2) {
            addCriterion("kilo42_time not between", value1, value2, "kilo42Time");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2IsNull() {
            addCriterion("kilo42_time2 is null");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2IsNotNull() {
            addCriterion("kilo42_time2 is not null");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2EqualTo(Long value) {
            addCriterion("kilo42_time2 =", value, "kilo42Time2");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2NotEqualTo(Long value) {
            addCriterion("kilo42_time2 <>", value, "kilo42Time2");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2GreaterThan(Long value) {
            addCriterion("kilo42_time2 >", value, "kilo42Time2");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2GreaterThanOrEqualTo(Long value) {
            addCriterion("kilo42_time2 >=", value, "kilo42Time2");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2LessThan(Long value) {
            addCriterion("kilo42_time2 <", value, "kilo42Time2");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2LessThanOrEqualTo(Long value) {
            addCriterion("kilo42_time2 <=", value, "kilo42Time2");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2In(List<Long> values) {
            addCriterion("kilo42_time2 in", values, "kilo42Time2");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2NotIn(List<Long> values) {
            addCriterion("kilo42_time2 not in", values, "kilo42Time2");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2Between(Long value1, Long value2) {
            addCriterion("kilo42_time2 between", value1, value2, "kilo42Time2");
            return (Criteria) this;
        }

        public Criteria andKilo42Time2NotBetween(Long value1, Long value2) {
            addCriterion("kilo42_time2 not between", value1, value2, "kilo42Time2");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}